// styled-components 
// 样式组件？ 样式带来变量， 嵌套等高级功能， 
// 以组件的形式返回， 声明式的css组件
import styled, { createGlobalStyle }  from 'styled-components'
import style from '@/assets/global-style'

export const GlobalStyle = createGlobalStyle`
html, body, div, span, applet, object, iframe,
  h1, h2, h3, h4, h5, h6, p, blockquote, pre,
  a, abbr, acronym, address, big, cite, code,
  del, dfn, em, img, ins, kbd, q, s, samp,
  small, strike, strong, sub, sup, tt, var,
  b, u, i, center,
  dl, dt, dd, ol, ul, li,
  fieldset, form, label, legend,
  table, caption, tbody, tfoot, thead, tr, th, td,
  article, aside, canvas, details, embed, 
  figure, figcaption, footer, header, hgroup, 
  menu, nav, output, ruby, section, summary,
  time, mark, audio, video {
    margin: 0;
    padding: 0;
    border: 0;
    font-size: 100%;
    font: inherit;
    vertical-align: baseline;
  }
  /* HTML5 display-role reset for older browsers */
  article, aside, details, figcaption, figure, 
  footer, header, hgroup, menu, nav, section {
    display: block;
  }
  body {
    line-height: 1;
  }
  html, body{
    background: #f2f3f4;;
  }
  ol, ul {
    list-style: none;
  }
  blockquote, q {
    quotes: none;
  }
  blockquote:before, blockquote:after,
  q:before, q:after {
    content: '';
    content: none;
  }
  table {
    border-collapse: collapse;
    border-spacing: 0;
  }
  a{
    text-decoration: none;
    color: #fff;
  }
`
export const Top = styled.div`
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    padding: 0.25rem 0.5rem;
    background: ${style["theme-color"]};
    & > span {
        line-height: 2rem;
        color: #f1f1f1;
        font-size: 1rem;
        &.iconfont {
            font-size: 25px;
        }
    }
`

export const Tab = styled.div`
  height: 2.2rem;
  display: flex;
  flex-direction: row;
  justify-content: space-around;
  background: ${style["theme-color"]};
  a {
    flex: 1;
    padding: 0.1rem 0;
    font-size: 0.7rem;
    color: #e4e4e4;
    &.active {
      span {
        padding: 0.15rem 0;
        font-weight: 700;
        color: #f1f1f1;
        border-bottom: 0.1rem solid #f1f1f1;
      }
    }
  }
`;

export const TabItem = styled.div`
  height: 100%;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
`;